﻿using System.Web.Mvc;
using KLS.PPDS.Utility;

namespace KLS.PPDS.Web.Controllers 
{
    /// <summary>
    /// Handles request from Home Page
    /// </summary>
    [HandleError]
    public class HomeController : Controller
    {

        /// <summary>
        /// return login page or home page
        /// </summary>
        /// <returns></returns>
        public ActionResult Index()
        {
        //    CommonTask.SetCulture("de-DE");
            if (Session["LoggedIn"] !=null)
            {
                CommonTask.SetCulture(CommonSession.Language);
                return View();
            }
            else
            {

                return RedirectToAction("Index", "Login");
            }

        }

    }
}
